package com.shop.entity;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.extension.activerecord.Model;
import lombok.AllArgsConstructor;
import lombok.Data;
import lombok.NoArgsConstructor;
import lombok.ToString;
import org.springframework.format.annotation.DateTimeFormat;

import java.util.Date;
import java.util.List;

/**
 * (MerchantBasket)表实体类
 *
 * @author yyt
 * @since 2020-11-24 10:18:39
 */
@Data
@ToString
@NoArgsConstructor
@AllArgsConstructor
public class MerchantBasket extends Model<MerchantBasket> {

    private Integer id;
    //商品名
    private String goodsName;
    //商品数量
    private Integer goodsNum;
    //商品类别
    private String goodsCategory;
    //商品规格
    private String goodsSize;
    //商品id
    private Integer goodsId;
    //商户id
    private Integer merchantId;
    //商品单价
    private Double unitPrice;
    //优惠价
    private Double concessionsPrice;
    //商品总价
    private Double totalPrice;
    //商户评分
    private Integer score;
    //商品的过期时间
    private Date expireTime;
    //商品备注
    private String remark;

    private Integer status;

    private Integer statusOne;

    private Integer statusTwo;

    private Integer createUserId;

    private Integer updateUserId;

    @DateTimeFormat(pattern = "yyyy-MM-dd hh:mm:ss")
    private Date createTime;
    @DateTimeFormat(pattern = "yyyy-MM-dd hh:mm:ss")
    private Date updateTime;

    private Integer isDeleted;
    //版本
    private Integer version;

    private long distributionPrice; //配送费

    private String merchantName; //商户名

    private String merchantAddress; //商户地址

    private String goodsPic; //商品图片

    private String checked; //是否被选中

    private MerchantMerchant merchant;

    private List<MerchantBasket> childMerchantBaskets;

    private Integer count; //前台传递的参数
    //新添字段
    private Integer userId;

    private Integer parentIndex;

    private Integer indexs;

    private double finalMoney;

    private double totalMoney;

    private double subtractMoney;

    public MerchantBasket(double finalMoney, double totalMoney, double subtractMoney) {
    }
}
